package com.wuqing.consumer.config;

import com.wuqing.TpRunService;
import org.apache.dubbo.config.annotation.Reference;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

/**
 * @author wuqing
 * @date 2020/8/8
 */
@Configuration
public class DubboConfig {

    @Reference(version = "${demo.service.version}",
            // application = "${dubbo.application.id}",
            // registry = "${dubbo.registry.id}",
            interfaceClass = TpRunService.class,
            check = false)
    private TpRunService tpRunService;

    @Bean(name = "tpRunService")
    public TpRunService tpRunService() {
        return tpRunService;
    }

}